
export default {
  namespaced: true,
  state: {
    token: '',
    userInfo: {},
    userRole: []
  },

  getters: {
    token (_state) {
      return _state.token
    },
    userInfo: _state => _state.userInfo,
    userRole: _state => _state.userRole
  },
  mutations: {
    setToken (_state, _token) {
      _state.token = _token
    },
    setUserInfo (_state, _userInfo) {
      _state.userInfo = _userInfo
    },
    setUserRole (_state, _userRole) {
      _state.userRole = _userRole
    }
  }
}
